KitePlayerPictureInPicture
Puts the canvas a web player draws into in a small window above the viewer's other windows.
createOrNull picks the first of two browser features that this browser has:
WebPictureInPictureMode.DocumentWindow. The canvas itself moves into the window, so everything the renderer draws comes along. An empty element of the canvas's size, with the class
kiteplayer-pip-placeholder, keeps its place in the page. When the window closes, the canvas goes back in its place.WebPictureInPictureMode.VideoElement. A hidden, muted video element plays a live capture of the canvas, and the window's play and pause buttons play and pause the player.
A browser opens the window only inside the viewer's own click, so start asks at once and never suspends. Call it from the click handler itself, with nothing awaited before it.
Properties
Functions
Calls stop, releases what createOrNull prepared, and refuses every later start.